function users() {
	var grid = tab.add(new Ext.grid.GridPanel({
		closable: true,
		columns: [
			{ dataIndex: 'id',       header: '用户名' },
			{ dataIndex: 'password', header: '密码' },
			{ dataIndex: 'enabled',  header: '已激活', renderer: booleanRenderer }
		],
		store: new Ext.data.JsonStore({
			fields: [ 'id', 'password', 'enabled' ],
			id: 'id',
			root: 'records',
			sortInfo: { field: 'id' },
			url: 'users/'
		}),
		title: '用户列表'
	}));
	
	grid.getColumnModel().defaultSortable = true;
	
	grid.on('rowdblclick', function() {
		new Ext.Window({
			bbar: ['->', {
					handler: function() {
						submit(function() {
							Ext.Msg.show({
								buttons: Ext.MessageBox.OK,
								fn: function() {
									close();
									grid.store.load();
								},
								icon: Ext.MessageBox.INFO,
								msg: '用户编辑已成功 请等待审批',
								title: '信息'
							});
						}, { __http_method: 'PUT' });
					},
					text: '确定'
				},
				'-', { handler: reset, text: '重置' },
				'-', { handler: close, text: '取消' }
			],
			bodyStyle: 'padding: 20px 20px 20px 25px',
			defaults: { baseCls: 'x-plain' },
			items: [
				new Ext.form.FormPanel({
					bodyStyle: 'padding: 0 0 10px 0',
					defaults: { allowBlank: false, vtype: 'alphanum', width: 225 },
					defaultType: 'textfield',
					items: [
						{ name: 'id',               disabled:  true,       fieldLabel: '用户名' },
						{ name: 'password',         inputType: 'password', fieldLabel: '密&nbsp;&nbsp;&nbsp;码* 字母/数字 6 ~ 32 位' },
						{ name: 'confirm_password', inputType: 'password', fieldLabel: '确认密码* 请与密码保持一致' },
						{ name: 'enabled',          hideLabel: true,       boxLabel:   '激活此用户', value: 'true', xtype: 'checkbox' }
					],
					labelAlign: 'top',
					labelWidth: 40,
					url: 'users/' + this.getSelectionModel().getSelected().id
				}),
				new Ext.Panel({ html: '带有 * 记号的为必填项' })
			],
			title: '用户编辑',
			width: 305
		}).show(null, load);
	});
}
